package com.leyou.item.pojo;


import org.springframework.transaction.annotation.Transactional;
import tk.mybatis.mapper.annotation.KeySql;

import javax.persistence.Id;
import javax.persistence.Table;
import javax.persistence.Transient;
import java.io.Serializable;
import java.util.List;

/**
 * 规格组
 */
@Table(name = "tb_spec_group")
public class SpecGroup implements Serializable {

    @Id
    @KeySql(useGeneratedKeys = true)
    private Long id;

    private Long cid;

    private  String name;

    @Transient
    private List<SpecParam> specParamList;

    public List<SpecParam> getSpecParamList() {
        return specParamList;
    }

    public void setSpecParamList(List<SpecParam> specParamList) {
        this.specParamList = specParamList;
    }

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Long getCid() {
        return cid;
    }

    public void setCid(Long cid) {
        this.cid = cid;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }



    @Override
    public String toString() {
        return "SpecGroup{" +
                "id=" + id +
                ", cid=" + cid +
                ", name='" + name + '\'' +
                '}';
    }
}
